<?php
include 'header.php';
?>
				<div class='col-xs-3'>
   					<div class='panel panel-primary'>
   						<div class='panel-heading'>
   							<div class='panel-title'>添加职员</div>
   						</div>
   						<form class='form-horizontal' action='addWorkerPro.php' method='post'>
	   						<div class='panel-body'>
	   							<?php if(!empty($mes)){?>
   									<div class='alert alert-danger'>
   										<?php @print($mes);?>
   										<div class='close' data-dismiss='alert'>&times;</div>
   									</div>
	   							<?php }?>
	   							<div class='row'>
	   								<div class='col-xs-8 col-xs-offset-3'>
	   									<img src='img/default.jpg' />
	   								</div>
   								</div>
   								<div class='form-group'>
   									<label class='col-xs-3 control-label' for='file'>头像</label>
   									<div class='col-xs-9'>
   										<input class='form-control' name='file' id='file' type='file' />
   									</div>
   								</div>
	   							<div class='form-group'>
	   								<label class='col-xs-3 control-label' for='name'>名称</label>
	   								<div class='col-xs-9'>
	   									<input class='form-control' name='name' id='name' type='text' placeholder="名称" required='required' />
	   								</div>
	   							</div>
	   							<div class='form-group'>
   									<label class='col-xs-3 control-label' for='age'>年龄</label>
   									<div class='col-xs-9'>
   										<input class='form-control' name='age' id='age' type='number' required='required' placeholder='年龄' />
   									</div>
   								</div>
	   							<div class='form-group'>
	   								<label class='col-xs-3 control-label' for='sex'>性别</label>
	   								<div class='col-xs-9'>
	   									<select class='form-control' id='sex' name='sex'>
	   										<option value='男'>男</option>
	   										<option value='女'>女</option>
	   									</select>
	   								</div>
	   							</div>
	   							<div class='form-group'>
   									<label class='col-xs-3 control-label' for='phone'>电话</label>
   									<div class='col-xs-9'>
   										<input class='form-control' name='phone' id='phone' type='number' required='required' placeholder='电话' />
   									</div>
   								</div>
	   							<div class='form-group'>
	   								<label class='col-xs-3 control-label' for='location'>地址</label>
	   								<div class='col-xs-9'>
	   									<input class='form-control' name='location' id='location' type='text' placeholder="地址" required='required' />
	   								</div>
	   							</div>
	   							<div class='form-group'>
	   								<label class='col-xs-3 control-label' for='branch_id'>部门</label>
	   								<div class='col-xs-9'>
	   									<select class='form-control' id='branch_id' name='branch_id'>
	   										<?php foreach ($branchs as $branch){?>
		   										<option value='<?php echo $branch['id'];?>'><?php echo $branch['name'];?></option>
		   									<?php }?>
	   									</select>
	   								</div>
	   							</div>
	   						</div>
	   						<div class='panel-footer text-center'>
   								<button class='btn btn-primary' type='submit'>确定</button>
   								<a href='index.php' class='btn btn-default'>返回</a>
   							</div>
   						</form>
   					</div>
   				</div>
			</div>
		</div>
	<script>
		$(function(){
			
		});
	</script>  
	</body>
</html>